package com.myspring.pojo;

import com.print.Printer;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class TestUser {
    public static void main(String[] args) {
        ApplicationContext context=new ClassPathXmlApplicationContext("beans.xml");
        UserService userService= context.getBean("userService",UserService.class);
        //userService.add(new User(1001,"zhangsan","123"));
        User user=new User(1001,"zhangsan","1234567");
        userService.add(user);
        userService.del(user);
        userService.update(user);



    }




}
